﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;

namespace AutofacOwinDemo
{
    public class HelloController : ApiController
    {
        public ITest Test { get; set; }
        public Test2 Test2 { get; set; }
        public HelloController() { }
        public HelloController(ITest test,Test2 test2)
        {
            Test = test;
            Test2 = test2;
        }
        // GET api/<controller>
        [Route("api/values/")]
        public IEnumerable<string> Get()
        {
            return new string[] { "value1", "value2",Test.Hello(),Test2.Hello() };
        }

        // GET api/<controller>/5
        public string Get(int id)
        {
            return "value";
        }

        // POST api/<controller>
        public void Post([FromBody]string value)
        {
        }

        // PUT api/<controller>/5
        public void Put(int id, [FromBody]string value)
        {
        }

        // DELETE api/<controller>/5
        public void Delete(int id)
        {
        }
    }
}